Optimal. Leaf size=27 \[ \frac {\text {Li}_2\left (\frac {g (c+d x)}{a+b x}\right )}{b c-a d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.08, antiderivative size = 27, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 3, integrand size = 38, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.079, Rules used = {2571, 2565,
2352} \begin {gather*} \frac {\text {PolyLog}\left (2,\frac {g (c+d x)}{a+b x}\right )}{b c-a d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2352
Rule 2565
Rule 2571
Rubi steps
\begin {align*} \int \frac {\log \left (\frac {a-c g+b x-d g x}{a+b x}\right )}{(a+b x) (c+d x)} \, dx &=\int \frac {\log \left (\frac {a-c g+(b-d g) x}{a+b x}\right )}{(a+b x) (c+d x)} \, dx\\ &=-\frac {g \text {Subst}\left (\int \frac {\log (x)}{1-x} \, dx,x,\frac {a-c g+(b-d g) x}{a+b x}\right )}{b (a-c g)-a (b-d g)}\\ &=\frac {\text {Li}_2\left (\frac {g (c+d x)}{a+b x}\right )}{b c-a d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [B] Leaf count is larger than twice the leaf count of optimal. \(320\) vs. \(2(27)=54\).
time = 0.13, size = 320, normalized size = 11.85 \begin {gather*} \frac {\log ^2\left (\frac {(b c-a d) g}{(b-d g) (a+b x)}\right )-2 \log \left (\frac {d (a+b x)}{-b c+a d}\right ) \log (c+d x)+2 \log (c+d x) \log \left (-\frac {d (a-c g+b x-d g x)}{b c-a d}\right )+2 \log \left (\frac {(b c-a d) g}{(b-d g) (a+b x)}\right ) \log \left (-\frac {b (a-c g+b x-d g x)}{(b c-a d) g}\right )-2 \log \left (\frac {(b c-a d) g}{(b-d g) (a+b x)}\right ) \log \left (\frac {a-c g+b x-d g x}{a+b x}\right )-2 \log (c+d x) \log \left (\frac {a-c g+b x-d g x}{a+b x}\right )-2 \text {Li}_2\left (\frac {(b-d g) (a+b x)}{(b c-a d) g}\right )-2 \text {Li}_2\left (\frac {b (c+d x)}{b c-a d}\right )+2 \text {Li}_2\left (\frac {(b-d g) (c+d x)}{b c-a d}\right )}{2 b c-2 a d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.74, size = 45, normalized size = 1.67
method | result | size |
derivativedivides | \(-\frac {\dilog \left (\frac {-d g +b}{b}+\frac {g \left (a d -c b \right )}{b \left (b x +a \right )}\right )}{a d -c b}\) | \(45\) |
default | \(-\frac {\dilog \left (\frac {-d g +b}{b}+\frac {g \left (a d -c b \right )}{b \left (b x +a \right )}\right )}{a d -c b}\) | \(45\) |
risch | \(-\frac {\dilog \left (\frac {-d g +b}{b}+\frac {g \left (a d -c b \right )}{b \left (b x +a \right )}\right )}{a d -c b}\) | \(45\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 343 vs.
\(2 (26) = 52\).
time = 0.31, size = 343, normalized size = 12.70 \begin {gather*} {\left (\frac {\log \left (b x + a\right )}{b c - a d} - \frac {\log \left (d x + c\right )}{b c - a d}\right )} \log \left (-\frac {d g x + c g - b x - a}{b x + a}\right ) + \frac {\log \left (b x + a\right )^{2} - 2 \, \log \left (b x + a\right ) \log \left (d x + c\right )}{2 \, {\left (b c - a d\right )}} - \frac {\log \left (b x + a\right ) \log \left (\frac {{\left (d g - b\right )} a + {\left (b d g - b^{2}\right )} x}{b c g - a d g} + 1\right ) + {\rm Li}_2\left (-\frac {{\left (d g - b\right )} a + {\left (b d g - b^{2}\right )} x}{b c g - a d g}\right )}{b c - a d} + \frac {\log \left (d x + c\right ) \log \left (\frac {c d g - b c + {\left (d^{2} g - b d\right )} x}{b c - a d} + 1\right ) + {\rm Li}_2\left (-\frac {c d g - b c + {\left (d^{2} g - b d\right )} x}{b c - a d}\right )}{b c - a d} + \frac {\log \left (b x + a\right ) \log \left (\frac {b d x + a d}{b c - a d} + 1\right ) + {\rm Li}_2\left (-\frac {b d x + a d}{b c - a d}\right )}{b c - a d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.39, size = 38, normalized size = 1.41 \begin {gather*} \frac {{\rm Li}_2\left (\frac {c g + {\left (d g - b\right )} x - a}{b x + a} + 1\right )}{b c - a d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.04 \begin {gather*} \int \frac {\ln \left (\frac {a-c\,g+b\,x-d\,g\,x}{a+b\,x}\right )}{\left (a+b\,x\right )\,\left (c+d\,x\right )} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________